package com.trxy.hotelsystem.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.trxy.hotelsystem.dao.consumptionRecordMapper;
import com.trxy.hotelsystem.model.consumptionRecord;
import com.trxy.hotelsystem.service.Consumption_recordService;

@Service
public class Consumption_recordServiceImpl implements Consumption_recordService{
	
	@Autowired
	private consumptionRecordMapper consumptionRecordmapper;

	@Override
	public int insertConsumption_record(consumptionRecord consumptionRecord) {
		// TODO Auto-generated method stub
		return consumptionRecordmapper.insertSelective(consumptionRecord);
	}

	@Override
	public List<consumptionRecord> selectConsumption_recordByvipNumber(String vipNumber) {
		// TODO Auto-generated method stub
		return consumptionRecordmapper.selectConsumption_recordByvipNumber(vipNumber);
	}

	@Override
	public int updaConsumption_recordByserialnum(consumptionRecord consumptionRecord) {
		// TODO Auto-generated method stub
		return consumptionRecordmapper.updateByPrimaryKeySelective(consumptionRecord);
	}

	@Override
	public List<consumptionRecord> queryConsumption_recordAll() {
		// TODO Auto-generated method stub
		return consumptionRecordmapper.queryConsumption_recordAll();
	}

	@Override
	public List<consumptionRecord> selectConsump_Record(consumptionRecord consumptionRecord) {
		// TODO Auto-generated method stub
		return consumptionRecordmapper.selectConsump_Record(consumptionRecord);
	}

	@Override
	public double sumConsump_RecordByvipNumber(String vipNumber) {
		// TODO Auto-generated method stub
		return consumptionRecordmapper.sumConsump_RecordByvipNumber(vipNumber);
	}



}
